categories = unique(mergedData.ccc);

categorySalesData = struct('Category', {}, 'Data', {});

% 遍历每个单品品类
for i = 1:numel(categories)
    category = categories{i};
    disp(['Category: ', category]);
    
    % 获取当前品类的数据
    categoryData = mergedData(strcmp(mergedData.ccc, category), :);
    
    % 将当前品类的数据存储到结构数组中
    categorySalesData(i).Category = category;
    categorySalesData(i).Data = categoryData;
end



% 显示保存在 MATLAB 内存中的每个单品品类的详细销售数据
for i = 1:numel(categorySalesData)
    disp(['Category: ', categorySalesData(i).Category]);
    disp(categorySalesData(i).Data);
end